package com.zhibang.mapstruct;

import com.zhibang.entity.Shop;
import com.zhibang.vo.ShopCasVo;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.factory.Mappers;

import java.util.List;

/**
 * @autor 流萤微微
 * @date 2025年03月08日 9:01
 */
@Mapper
public interface ShopMapstruct {
    ShopMapstruct instance = Mappers.getMapper(ShopMapstruct.class);

    @Mapping(source = "name", target = "label")
    @Mapping(source = "id", target = "value")
    ShopCasVo toShopCasVo(Shop shop);

    List<ShopCasVo> toShopCasVoList(List<Shop> shopList);
}
